package com.itheima.automaticexception;

public class Demo3 {
    public static void main(String[] args) {
        Person p1 =  new Person("老王",30);
        p1.keepPet(new Dog(2,"黑"),"骨头");

        Person p2 = new Person("老李",25);
        p2.keepPet(new Cat(3,"灰"),"鱼");
    }
}
